import com.flower.CoreServiceApplication;
import com.flower.core_service.object.entity.AuthRole;
import com.flower.core_service.object.entity.AuthUser;
import com.flower.core_service.service.AuthRoleService;
import com.flower.core_service.service.AuthUserService;
import lombok.extern.slf4j.Slf4j;
import org.junit.Test;
import org.junit.runner.RunWith;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.test.context.SpringBootTest;
import org.springframework.test.context.junit4.SpringRunner;

import java.util.List;

/**
 * @ClassName Coretest
 * @Description TODO
 * @Author 吃麻椒的花酱
 * @Date 2022/3/24 18:07
 * @Version 1.0
 */
@Slf4j
@SpringBootTest(classes= CoreServiceApplication.class)
@RunWith(SpringRunner.class)
public class Coretest {
    @Autowired
    AuthRoleService authRoleService;

    @Autowired
    AuthUserService authUserService;

    @Test
    public void test() {
        List<AuthRole> roles= authRoleService.findAllRoles();
        log.info(roles.toString());
    }

    @Test
    public void userTest(){
        final List<AuthUser> allUser = authUserService.getAllUser();
        log.info(allUser.toString());
    }
}
